
/* Style the entire page */
*{
    box-sizing: border-box;
    margin: 0;
    overflow: hidden;
}

:root{
    --rowHeight: 0px;
    --legendHeight: 800px;
    --legendColourRowHeight:100px;
    --legendLabelRowHeight:100px;

    --vtkBackgroundColour:rgb(247, 247, 247);
    --panelBackgroundColour:rgb(255, 255, 255);
}




body {font-family: 'Montserrat', sans-serif;}

/* Style the grid */
.wrapper {
    display: grid;
    grid-template-columns: 3fr 2fr;
    grid-template-rows: auto 3fr 2fr;
    width: 100vw;
    height: 100vh;
    grid-template-areas:
        "a t"
        "a d"
        "a e";
    background-color: var(--vtkBackgroundColour);
    padding: 3px;
    grid-gap: 3px;
}

#viewer {
    grid-area: a;
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    grid-template-areas:
        "f g"
        "h i";
}
.topRightPanel {
    min-width: 250px;
    grid-area: d;
    background-color: var(--panelBackgroundColour);
    z-index: 1;
    box-shadow: 0px 2px 6px 0px rgba(50,50,50,0.2);
}
.bottomRightPanel {
    grid-area: e;
    background-color: var(--panelBackgroundColour);
    z-index: 1;
    box-shadow: 0px 2px 6px 0px rgba(50,50,50,0.2);
}
#tabContainer {
    grid-area: t;
    z-index: 1;
    box-shadow: 0px 2px 6px 0px rgba(50,50,50,0.2);
}


#registrationGraphPanel {
    padding: 10px;
    height: 100%;
}
#csaGraphReg {
    height: 40vh;
    width: 50vw;
}
#csaGraphAnalyse     {
    height: 40vh;
    width: 50vw;
}
.plot-container {
    height: 100%;
    width: 100%;
}


.alignViewContainer {
    margin: 1px;
    border-style: solid;
    border-width: thin;
    border-color: rgb(150, 150, 150);
}
#topLeftViewer {
    grid-area: f;
}
#topRightViewer {
    grid-area: g;
    cursor: default;
}
#bottomLeftViewer {
    grid-area: h;
    cursor: default;
}
#bottomRightViewer {
    grid-area: i;
    cursor: default;
}

#mainViewer {
    grid-area: 1 / 1 / span 2 / span 2;
}

.analyseViewContainer {
    margin: 3px;
    padding: 5px;
    /*border-style: solid;*/
    /*border-width: thin;*/
    /*border-color: rgb(150, 150, 150);*/
    box-shadow: 0px 2px 6px 0px rgba(50,50,50,0.2);
    background-color: rgb(255, 255, 255);
}
#topLeftAnalyseViewer {
    grid-area: f;
}
#topRightAnalyseViewer {
    grid-area: g;
}
#bottomLeftAnalyseViewer {
    grid-area: h;
}
#bottomRightAnalyseViewer {
    grid-area: i;
    text-align: center;
    line-height: 50vh;
}



/*Loading screen*/
#loadingScreen {
    position: absolute;
    display: block;
    background-color: rgba(220, 220, 220, 0.98);
    width: 100vw;
    height: 100vh;
    z-index: 2;
    animation-duration: 1s;
    animation-delay: 0.1s;
    animation-fill-mode: forwards;
    pointer-events:all;
}
@keyframes loading {
    from {
        background-color: rgba(220, 220, 220, 0.98);
        pointer-events: all;
    }
    to {
        background-color: rgba(50, 50, 50, 0);
        pointer-events:none;
    }
}
#loadingLogo {
    width: 100vw;
    height: 100vh;
    animation-duration: 0.5s;
    animation-fill-mode: forwards;
}
@keyframes loadingLogo {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}


/* Scalar bar styling*/
#scalarBarContainer {
    width: 8vw;
    min-width: 90px;
    min-height: 350px;
    height: 50vh;
    z-index: 5;
    position: absolute;
    right: calc(40vw + 5px);
    top:0;
    margin:3px;
    display: none;
    grid-template-columns: calc(45% - 5px) calc(45% - 5px);
    grid-template-rows: 70px calc(100% - 80px);
    grid-template-areas:
        "scalar1 scalar1"
        "scalar2 scalar3";
    box-shadow: 0px 2px 6px 0px rgba(50,50,50,0.2);
    background-color: var(--panelBackgroundColour);
}
#legend {
    background-color: rgba(0, 0, 0, 0);
    height: 100%;
}
#keyLabel {
    margin: 5px;
    grid-area: scalar1;
    height: 60px;
    font-size: 16px;
    background-color: rgba(0, 0, 0, 0);
}

.legend{
    grid-area: scalar2;
    height: var(--legendHeight);
}
#colourList {
    margin: 0px;
    padding: 0px;
    background-color: rgba(0, 0, 0, 0);
}
.colourLegend{
    height: var(--legendColourRowHeight);
    width: 100%;
    margin: 0px;
    padding: 0px;
}

#scaleContainer {
    height: 100%;
    background-color: rgba(0, 0, 0, 0);
    grid-area: scalar3;
}
.tickLegend {
    padding-left: 10px;
    border-top: solid 1px darkgrey;
    height: var(--legendLabelRowHeight);
    width: 30px;
    text-align: left;
}


/* The switch - the box around the slider */
.switch {
    position: relative;
    vertical-align: middle;
    display: inline-block;
    width: 60px;
    height: 24px;
}

/* Hide default HTML checkbox */
.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

/* The slider */
.toggleSlider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: darkgrey  ;
    -webkit-transition: 0.2s;
    transition: 0.2s;
    border-radius: 4px;
    box-shadow: 0px 2px 6px 0px rgba(50,50,50,0.2);
}

.toggleSlider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 20px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    -webkit-transition: 0.2s;
    transition-timing-function: ease-out;
    transition: 0.2s;
    border-radius: 3px;

}

input:checked + .toggleSlider {
    background-color: mediumseagreen;
}

input:focus + .toggleSlider {
    box-shadow: 0 2px 4px 0 rgba(100,100,100,0.1);
}

input:checked + .toggleSlider:before {
    -webkit-transform: translateX(32px);
    -ms-transform: translateX(32px);
    transform: translateX(32px);
}




/* Style the control panel tab */
.tab {
    overflow: auto;
    border: 1px solid #ccc;
    background-color: #f1f1f1;
    white-space: nowrap;
    display: flex;
    /*padding-right: 5px;*/
    /*padding-left: 5px;*/
    /*alignment: right;*/
    /*align-items: stretch;*/
}
.tab button {
    /*margin-right: 5px;*/
    /*margin-left: 5px;*/
    float: right;
    background-color: inherit;
    /*float: left;*/
    border: none;
    outline: none;
    cursor: pointer;
    padding: 14px 16px;
    transition: 0.4s;
    font-size: 15px;
    font-family: 'Montserrat', sans-serif;
    border-radius: 0px;
    box-shadow: none;
}
.tab button:hover {
    background-color: rgb(225, 225, 225);
}
.tab button.active {
    background-color: rgb(190, 190, 190);
    color: seagreen;
    z-index:2;
}
.tabcontent {
    display: none;
    padding: 6px 12px;
}
/* Add fade anitmation */
@keyframes fadeEffect {
    from {opacity: 0;}
    to {opacity: 1;}
}

/* Object table styling */
table {
    border-collapse: collapse;
    border-spacing: 0;
    width: 100%;
    border: 1px solid rgb(190, 190, 190);
}
.objectTableCell {
    text-align: center;
    padding: 8px;
    border-bottom: 1px solid #ddd;
}
.objectTableRow:hover {
    background-color: #f2f2f2;
}

.analyseTableCell {
    text-align: center;
}


/* Overflow button styling*/
.overflowMenuCell {
    padding: 1px;
    width: 1px;
}
.objectOverflowButton {
    width: 50px;
    height: 100%;
    padding: 0;
    border: none;
    background: none;
}
.objectOverflowButton:after {
    content: '\2807';
}
.objectOverflowButton:hover {
    color: blue;
    cursor: pointer;
}
.objectOverflowButton:focus { outline: none; }

/* Overflow content (Hidden by Default) */
.overflowMenu {
    display: none;
    position: absolute;
    right: 0px;
    background-color: #f1f1f1;
    box-shadow: 0px 2px 6px 0px rgba(50,50,50,0.2);
    z-index: 1;
}
.overflowContainer {
    /*position: relative;*/
    display: inline-block;
}



/* Button Styling */
button, input, select {
    font-family: 'Montserrat', sans-serif;
}

button {
    font-size: 15px;
    border-color: #a9a9a9;
    border-style: solid;
    color: black;
    background: transparent;
    border-width: thin;
    border-radius: 4px;
    -webkit-transition-duration: 0.2s; /* Safari */
    transition-duration: 0.2s;
    box-shadow: 0 2px 4px 0 rgba(100,100,100,0.1);
    text-align: center;
}
button:active {
  background: #e5e5e5;
  -webkit-box-shadow: inset 0 0 5px #c1c1c1;
     -moz-box-shadow: inset 0 0 5px #c1c1c1;
          box-shadow: inset 0 0 5px #c1c1c1;
   outline: none;
}
button:hover {
    /*background-color: lightgray;*/
    color: seagreen;
    cursor: pointer;
    border-color: seagreen;
}
button:disabled,
button[disabled]{
    background-color: darkgrey;
    color: lightgray;
    cursor: default;
}





/* Control panel styling*/
.controlOptionLineContainer {
    position: relative;
    padding-bottom: 5px;
    padding-top: 5px;
    font-family: 'Montserrat', sans-serif;
    font-size: 15px;
    overflow: visible;
}

.targetDropdown {
    position: absolute;
    width: 100px;
    height: 80%;
    left: 80px;
    font-family: 'Montserrat', sans-serif;
    box-shadow: 0 2px 4px 0 rgba(100,100,100,0.1);
}

.targetColour {
    position: absolute;
    height: 80%;
    width: 25px;
    left: 190px;
    box-shadow: 0 2px 4px 0 rgba(100,100,100,0.1);
}

.targetOpacity {
    position: absolute;
    width: 100px;
    height: 80%;
    left: 225px;
}


/* Setting options container*/
.settingsOption {
    position: absolute;
    left: 150px;
}


/* Rotation and translation panel */
.axisIncrementButton {
    position: relative;
    width: 30px;
    height: 30px;
    font-size: 15px;
    display: inline-flex;
    margin-left: 5px;
}
.buttonContainer {
    position: relative;
}
.axisTransformContainerRotation, .axisTransformContainerTranslation{
    /*margin-left:15px;*/
    /*margin-bottom:5px;*/
    /*margin-top:5px;*/
    /*display:block;*/
    padding: 5px;
}
/*.axisTransformContainerTranslation {*/
/*    !*margin-left:15px;*!*/
/*    !*margin-bottom:5px;*!*/
/*    !*margin-top:5px;*!*/
/*    display:block;*/
/*}*/
#transformationContainer {
    display: inline-flex;
}
.axisTransformContainer {
    position: relative;
    font-family: 'Montserrat', sans-serif;
    font-size: 15px;
    display:inline;
    margin: 5px;
}
.axisContainer {
    position: relative;
    overflow: visible;
    padding-right: 30px;
    padding-top: 5px;
}


/* Tooltip text */
.tooltiptext {
    visibility: hidden;
    background-color: rgba(0.1, 0.1, 0.1, 0.5);
    color: #fff;
    text-align: center;
    padding: 5px 0;
    border-radius: 6px;
    position: absolute;
    z-index: 5;
    top: -5px;
    left: 130%;
}

/* Show the tooltip text when you mouse over the tooltip container */
.axisTransformContainer:hover .tooltiptext {
    overflow: auto;
    visibility: visible;
}

